package luogu;

import java.util.Scanner;

public class test2 {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        int[] apple=new int[10];
        for (int i = 0; i < 10; i++) {
            apple[i]=sc.nextInt();
        }
        int hight=sc.nextInt()+30;
        int count=0;
        for (int i = 0; i < apple.length; i++) {
            if(apple[i]<=hight){
                count++;
            }
        }
        System.out.println(count);

    }
}
